#include<stdio.h>
void main(){
	int h;
	printf("input height:");
	scanf("%d",&h);
	int i=1,j=1;
	while(i<=h){
		j=i;
		while(j<=h){
			printf(" ");
			j++;
		}
		j=1;
		while(j<=i*2-1){
			if(j==1||i==h ||j==i*2-1)
			   printf("*");
			else
			   printf(" ");
			j++;
		}
		i++;
		printf("\n");
	}
}
